/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.asseco.mio.codex;

import java.util.Date;
import javax.persistence.*;
import org.appfuse.model.BaseObject;
import org.hibernate.annotations.GenericGenerator;

/**
 *
 * @author filip.apostolski
 */
@Entity @Table(name="ASS_MARK")
public class AssMark extends BaseObject {

    private String id;
    private String name;
    private String assMarkCode;
    private String assMarkDescr;
    private Boolean status = true;
    private Date activeDate;
    private Date passiveDate;
    private float numAssMarkFrom;
    private float numAssMarkTo;

    @Column(name = "ACTIVE_DATE")
    @Temporal(value = javax.persistence.TemporalType.TIMESTAMP)
    public Date getActiveDate() {
        return activeDate;
    }

    public void setActiveDate(Date activeDate) {
        this.activeDate = activeDate;
    }

    @Column(name = "ASS_MARK_CODE", length = 255)
    public String getAssMarkCode() {
        return assMarkCode;
    }

    public void setAssMarkCode(String assMarkCode) {
        this.assMarkCode = assMarkCode;
    }

    @Column(name = "ASS_MARK_NAME", length = 1000)
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
    @Column(name = "ASS_MARK_DESCR", length = 4096)
    public String getAssMarkDescr() {
        return assMarkDescr;
    }

    public void setAssMarkDescr(String assMarkDescr) {
        this.assMarkDescr = assMarkDescr;
    }
    @Id
    @GeneratedValue(generator = "system-uuid")
    @Column(name = "ID", length = 255)
    @GenericGenerator(name="system-uuid", strategy = "uuid")
    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Column(name = "NUM_ASSESSMENT_FROM")
    public float getNumAssMarkFrom() {
        return numAssMarkFrom;
    }

    public void setNumAssMarkFrom(float numAssMarkFrom) {
        this.numAssMarkFrom = numAssMarkFrom;
    }

    @Column(name = "NUM_ASSESSMENT_TO")
    public float getNumAssMarkTo() {
        return numAssMarkTo;
    }

    public void setNumAssMarkTo(float numAssMarkTo) {
        this.numAssMarkTo = numAssMarkTo;
    }

    @Column(name = "PASSIVE_DATE")
    @Temporal(value = javax.persistence.TemporalType.TIMESTAMP)
    public Date getPassiveDate() {
        return passiveDate;
    }

    public void setPassiveDate(Date passiveDate) {
        this.passiveDate = passiveDate;
    }

    @Column(name = "STATUS")
    public Boolean getStatus() {
        return status;
    }

    public void setStatus(Boolean status) {
        this.status = status;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final AssMark other = (AssMark) obj;
        if ((this.id == null) ? (other.id != null) : !this.id.equals(other.id)) {
            return false;
        }
        if ((this.name == null) ? (other.name != null) : !this.name.equals(other.name)) {
            return false;
        }
        if ((this.assMarkCode == null) ? (other.assMarkCode != null) : !this.assMarkCode.equals(other.assMarkCode)) {
            return false;
        }
        if ((this.assMarkDescr == null) ? (other.assMarkDescr != null) : !this.assMarkDescr.equals(other.assMarkDescr)) {
            return false;
        }
        if (this.status != other.status) {
            return false;
        }
        if (this.activeDate != other.activeDate && (this.activeDate == null || !this.activeDate.equals(other.activeDate))) {
            return false;
        }
        if (this.passiveDate != other.passiveDate && (this.passiveDate == null || !this.passiveDate.equals(other.passiveDate))) {
            return false;
        }
        if (this.numAssMarkFrom != other.numAssMarkFrom) {
            return false;
        }
        if (this.numAssMarkTo != other.numAssMarkTo) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "AssMark{" + "id=" + id + "name=" + name + "assMarkCode=" + assMarkCode + "assMarkDescr=" + assMarkDescr + "status=" + status + "activeDate=" + activeDate + "passiveDate=" + passiveDate + "numAssMarkFrom=" + numAssMarkFrom + "numAssMarkTo=" + numAssMarkTo + '}';
    }

   

    

    @Override
    public int hashCode() {
        throw new UnsupportedOperationException("Not supported yet.");
    }
}
